package org.han.dao.impl;

import java.util.List;

import org.han.dao.BaseDao;
import org.han.dao.IUserDao;
import org.han.entity.User;

public class UserDaoImpl extends BaseDao<User> implements IUserDao{
	public User getUserByUname(String uname){
		List l=super.sessionFactory.getCurrentSession().createQuery("from User where u_name='"+uname+"'").list();
		if(l.size()>0&&l!=null){
			return (User)l.get(0);
		}
		return null;
	}
}
